import {http} from '@/core'

// 获取商机数量
export const GetBusinessCount = (param) => {
  return http.post('opportunity/mySalePeriodOppCounts', param)
}
// 获取商机基本信息（内含客户基本信息，时间提醒）
export const GetBusinessBaseInfo = (businessId) => {
  return http.get(`opportunity/getBaseInfo/${businessId}`)
}
// 获取商机销售阶段、财务阶段
export const GetBusinessPeriod = (businessId) => {
  return http.get(`opportunity/getStatus/${businessId}`)
}
// 获取商机最新日志
export const GetLatestLog = (param) => {
  return http.post('follow/follows', param)
}
// 获取商机销售团队
export const GetSalers = (businessId) => {
  return http.get(`saler/opplist/${businessId}`)
}
// 获取商机运营团队
export const GetOperators = (businessId) => {
  return http.get(`serviceTeam/${businessId}`)
}
// 获取商机联系人列表
export const GetContacts = (param) => {
  return http.post('contact/typeList', param)
}
// 获取商机需求方案
export const GetDemand = (businessId) => {
  return http.get(`demandScheme/get/${businessId}`)
}
// 获取商机寻求支持
export const GetSupport = (businessId) => {
  return http.get(`support/getList/${businessId}`)
}
// 获取商机成交预测
export const GetDealForecast = (businessId) => {
  return http.get(`businessMonthForecast/monthForecasts/${businessId}`)
}
// 获取商机回款预测
export const GetPaymentForecast = (businessId) => {
  return http.get(`businessFirstMonthForecast/monthForecasts/${businessId}`)
}
// 获取商机开票预测
export const GetBillForecast = (businessId) => {
  return http.get(`billForecast/billForecasts/${businessId}`)
}
// 获取商机合同信息
export const GetContracts = (param) => {
  return http.post('contract/contracts', param)
}
// 获取商机回款
export const GetPayments = (param) => {
  return http.post('payments/payments', param)
}
// 获取商机开票
export const GetBills = (param) => {
  return http.post('bill/bills', param)
}
// 获取商机结项
export const GetEnds = (businessId) => {
  return http.get(`itemInformation/getList/${businessId}`)
}
